﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="UCLHYueDuTZLC.ascx.cs" Inherits="Web.Controls.LAIHAN.YUEDUTZLC" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.9.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dx" %>

<%@ Register Src="~/Control/LAIHANLC/UCLHLCLAIHANXX.ascx" TagPrefix="uc1" TagName="UCLHLCLAIHANXX" %>
<%@ Register Src="~/Control/LAIHANLC/UCLHLCBTNS.ascx" TagPrefix="uc1" TagName="UCLHLCBTNS" %>
<%@ Register Src="~/Control/LAIHANLC/UCLHLCTOPINFO1.ascx" TagPrefix="uc1" TagName="UCLHLCTOPINFO1" %>
<%@ Register Src="~/Control/LAIHANLC/UCLHLCYIJIANS.ascx" TagPrefix="uc1" TagName="UCLHLCYIJIANS" %>
<%@ Register Src="~/Control/LAIHAN/UCLHXX_YDTZ.ascx" TagPrefix="uc1" TagName="UCLHXX_YDTZ" %>
<%@ Register Src="~/Control/LAIHANLC/UCLHLCSHENPI.ascx" TagPrefix="uc1" TagName="UCLHLCSHENPI" %>


<link href="/css/inputBgColor.css" rel="stylesheet"/>
<script type="text/javascript">
    function SetRowValue(values) {
        HiddenList.Set("laihanid", values);
        BtnLeftContent.onClick();
    }

    function SelectChange(s, e) {

        HiddenList.Set("h_glk", DrpGLK.GetValue());
        btnActPerform.onClick();
    }

    function OpenWJLB() {
        var yhh = "";
        var laihan = "";
        if (GetQueryString("id") != null) {

            yhh = HiddenList.Get("h_yonghuh");;
            laihan = HiddenList.Get("h_laihanbh");
        }
        var laihanlx = HiddenList.Get("laihanlc");
        OpenWenjian(laihan, yhh, laihanlx);

    }
    //function OpenSFXX() {
    //    var yhh = "";
    //    var laihan = "";
    //    if (GetQueryString("id") != null) {
    //        yhh = HiddenList.Get("h_yonghuh");;
    //        laihan = HiddenList.Get("h_laihanbh");
    //    }

    //    openCenter("YUEDuTZJHXX.aspx?yonghuh=" + yhh, "960px", "650px");

    //}
    //function OpenXXXX() {
    //    var yhh = "";
    //    var laihan = "";
    //    if (GetQueryString("id") != null) {
    //        yhh = HiddenList.Get("h_yonghuh");;
    //        laihan = HiddenList.Get("h_laihanbh");
    //    }

    //    openCenter("YUEDuTZXX.aspx?yonghubh=" + yhh + "&laihanbh=" + laihan, "960px", "650px");

    //}
    function OpenWenjian(laihanbh, yonghuh, laihanlc) {

        openCenter("LAIHANWJLB.aspx?laihanbh=" + laihanbh + "&yonghuh=" + yonghuh + "&laihanlx=1&laihanlc=" + laihanlc,
            "700px",
            "380px");
    }

    function EnterSelect() {
        if (event.keyCode == 13) {
            BtnBind.onClick();
        }
    }

    //function CheckQR() {
    //    ASPxCallback1.PerformCallback("queren");
    //}
    function ASPxCallbackCommonComplete(rs) {
        var keys = rs.split('|');
        var key = keys[0];
        var type = keys[1];
        var msg = keys[2];

        if (key == "queren") {
            if (type < 0) {

                alert(msg);
                txtFocus(type);
            } else if (type > 0) {
                BtnQRSUBMIT.onClick();
            }
        }

        if (key == "tijiao") {
            if (type < 0) {
                alert(msg);
            } else {
                //alert(msg);
                BtnTJSUBMIT.onClick();
            }
        }
    }

    function txtFocus(type) {
        if (event.keyCode != 13) {
            return;
        }
        if (type == -1) {
            YeWuYJYLSRK.Focus();
        } else if (type == -1) {
            YeWuYJYLSRK.Focus();
        } else if (type == -2) {
            YeWuYYJSRK.Focus();
        } else if (type == -3) {
            ZhuRenYJSRK.Focus();
        } else if (type == -4) {
            JieShuiYJSRL.Focus();
        } else if (type == -5) {
            JiCaiYJSRK.Focus();
        } else if (type == -6) {
            ChuZhangYJSRK.Focus();
        } else if (type == -7) {
            JiCaiLSRK.Focus();
        } else if (type == -8) {
            JiCaiYJSRK.Focus();
        } else if (type == -9) {
            ChuZhangLSRK.Focus();
        } else if (type == -10) {
            ChuZhangYJSRK.Focus();
        }
    }

    function BtnTJ() {
        ASPxCallback1.PerformCallback("tijiao");
    }

    function GetQueryString(name) {

        var result = location.search.match(new RegExp("[\?\&]" + name + "=([^\&]+)", "i"));

        if (result == null || result.length < 1) {

            return "";

        }

        return result[1];

    }

    function SetToControl(text) {
        if (YeWuYYJSRK.GetText() != "") {
            YeWuYYJSRK.SetText(YeWuYYJSRK.GetText() + "\n" + text);
        } else {
            YeWuYYJSRK.SetText(YeWuYYJSRK.GetText() + text);
        }
    }

    function SetToLAIHANNR(text) {
        txtLY.SetText(text);
    }

    function SetTextToInput(s1, type) {
        var txt = s1.GetText();
        if (type == 3) {
            YeWuYJYLSRK.SetText(txt);
        }
        if (type == 4) {
            ZhuRenJYLSRK.SetText(txt);
        }
        if (type == 5) {
            JieShuiLSRK.SetText(txt);
        }
        if (type == 6) {
            JiCaiLSRK.SetText(txt);
        }
        if (type == 7) {
            ChuZhangLSRK.SetText(txt);
        }

    }
</script>

<div class="tabletitle1" align="center">
    月度调整
</div>
<asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
<asp:UpdatePanel ID="updatePanel1" runat="server">
    <ContentTemplate>
        <fieldset style="border: 1px solid cornflowerblue;">
            <legend>
                <dx:ASPxLabel ID="lblFlowName" runat="server" Text=""></dx:ASPxLabel>
            </legend>
            <div style="width: 100%;">
                <div style="float: left; width: 24%;">
                    <uc1:UCLHLCLAIHANXX runat="server" ID="UCLHLCLAIHANXX" LaiHanLX="月度"/>
                </div>
                <div style="float: left; width: 1%;">
                    &nbsp;
                </div>
                <div id="divRight" style="float: left; width: 75%;">
                    <uc1:UCLHLCTOPINFO1 runat="server" ID="UCLHLCTOPINFO1" LaiHanLX="月度"/>
                    <div style="height: 3px;">
                    </div>
                    <div style="border: 0px solid cornflowerblue; padding: 0px; padding-bottom: 1px; width: 100%;">
                        <uc1:UCLHXX_YDTZ runat="server" ID="UCLHXX_YDTZ" LaiHanLX="月度"/>
                        <hr/>
                        <uc1:UCLHLCYIJIANS runat="server" ID="UCLHLCYIJIANS" LaiHanLX="月度"/>
                        <uc1:UCLHLCSHENPI runat="server" ID="UCLHLCSHENPI" LaiHanLX="月度"/>
                        <uc1:UCLHLCBTNS runat="server" ID="UCLHLCBTNS" LaiHanLX="月度"/>
                    </div>
                </div>
            </div>
        </fieldset>
    </ContentTemplate>
</asp:UpdatePanel>